import dcPageDesigner from "./designer/dcPageDesigner.vue";
import dcPageBuilder from "./builder/dcPageBuilder.vue";
import componentWrap from './designer/center/componentWrap.vue'
import dcIcon from './common/extens/dcIcon/dcIcon.vue'
import * as Icons from '@ant-design/icons-vue'

import componentDefault from './common/config/componentDefault.js';
import { registerComponent } from "./componentManager.js";

import './designer/style/designer-style.less'
import './common/style/font-awesome/css/all.min.css'

// 组件列表
let comps = [dcPageDesigner, dcPageBuilder, componentWrap, dcIcon];

const install = (app, options) => {
    // 注册内置组件
    registerComponent(componentDefault);

    // 注册antd图标
    const icons = Icons
    for (const i in icons) {
        app.component(i, icons[i])
    }

    comps.forEach(comp => {
        app.component(comp.name, comp);
    });
}

export default install

export * from './manager.js'
